#set property

function(set_tgt_debug_env tgt env_dir_list)
	if(MSVC)
		if(${ARGC} LESS 2)
			message(WARING "set_tgt_debug_env args is not enough!")
		endif()
		
		set(env_dirs "")
		string(CONCAT env_dirs "${env_dirs}" "${env_dir_list}\;")
		foreach(env_dir IN LISTS ARGN)
			string(CONCAT env_dirs "${env_dirs}" "${env_dir}\;")
		endforeach()
		
		set(VS_DEBUG_ENV "PATH=${env_dirs}$(PATH)")
		set_target_properties(${tgt} PROPERTIES VS_DEBUGGER_ENVIRONMENT ${VS_DEBUG_ENV})
		
	else()
		message(STATUS "the compiler is not msvc")
	endif()
endfunction()

function(set_tgt_debug_exe tgt exe_path )
	if(MSVC)
		if(${ARGC} LESS 2)
			message(WARING "set_tgt_debug_exe args is not enough!")
		endif()
		set_target_properties(${tgt} PROPERTIES VS_DEBUGGER_COMMAND ${exe_path} )
	endif()
endfunction()
